class Fu {
    public String num = "父变量";
        public void show() {
            System.out.println(this.num);
            System.out.println(this.fun1());
        }
    public String fun1() {
        System.out.println(this.num);
        return "父类调用";
    }
}

class Zi extends Fu {
    public String num=  "子变量";
    public String fun1() {
        System.out.println(this.num);
        return "子类调用";
    }
}
public class Demo {
    public static void main(String[] args){
        Fu f= new Zi();
        System.out.println(f.num);
        System.out.println(f.fun1());
        f.show();
    }
}

